<?php 

/**
 * @version $Id: router_copy.php,v 1.2 2009/06/03 00:59:06 dgravato Exp $
 * @package    sketchup
 * @subpackage 

 * @author     Chris Borkowski {@link http://www.guggenheim.org}
 * @author     Created on 01-April-2009
 */

// no direct access
defined( '_JEXEC' ) or die( 'Restricted access' ); 

function SketchupBuildRoute(&$query)
{
	$segments = array();
	
	if (isset($query['view'])) {
		$segments[] = $query['view'];
		unset($query['view']);
	}
	
	if (isset($query['id'])) {
		$segments[] = $query['id'];
		unset($query['id']);
	}
	
	return $segments;
}

function SketchupParseRoute($segments) 
{
	$vars = array();
	
	if (isset($segments[0])) {
		$vars['view'] = $segments[0];
	}
	
	if (isset($segments[1])) {
		$vars['id'] = $segments[1];
	}
	
	return $vars;
}


?>


